package com.xiaoshuidi.cloud.module.guanwang.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler;
import com.xiaoshuidi.cloud.framework.tenant.core.db.TenantBaseDO;
import com.xiaoshuidi.cloud.module.guanwang.service.GuanWangConfiguration;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

@Data
@TableName(value = "guanwang_config", autoResultMap = true)
@EqualsAndHashCode(callSuper = true)
@ToString(callSuper = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class GuanWangConfig extends TenantBaseDO {

    @TableId(type = IdType.AUTO)
    @Schema(description = "id")
    private Long id;

    @Schema(description = "状态，0：失效，1：有效")
    private Integer status;

    @Schema(description = "配置项序号")
    private Integer indexId;

    @Schema(description = "配置项名称")
    private String itemName;

    @Schema(description = "配置json")
    @TableField(typeHandler = JacksonTypeHandler.class)
    private GuanWangConfiguration configJson;
}
